<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>首页</title>
</head>
<body>
    <table border="1px" cellspacing="0px" cellpadding="5px" width="100%">
        <thead>
            <tr>
                <th>标题</th>
                <th>内容</th>
                <th>价格</th>
                <th>创建时间</th>
            </tr>
        </thead>
        <tbody>
            {% for article in articles %}
                <tr>
                    <td>{{ article.title }}</td>
                    <td width="50%">{{ article.content }}</td>
                    <td>{{ article.price }}</td>
                    <td>{{ article.create_time|date:"Y/m/d H:i:s" }}</td>
                </tr>
            {% endfor %}
        </tbody>
        <tfoot>
            <tr>
                <td colspan="4" style="text-align: center"><a href="{% url 'article:article' %}">新增文章</a></td>
            </tr>
        </tfoot>
    </table>
</body>
</html>